import { Component } from 'vue-facing-decorator'
import Render from '@/render/Render'
import toNative from '@/utils/toNative'
import ChannelGroup from './components/ChannelGroup'
import ReceiptAccountDetail from './components/ReceiptAccountDetail'

@Component
export class ReceiptAccount extends Render {
    activeId = 0
    onChannelClick(activeId: number) {
        this.activeId = activeId
    }
    render() {
        return <div class="h-full grid grid-cols-[280px,auto]">
            <ChannelGroup onClick={this.onChannelClick}/>
            <ReceiptAccountDetail activeId={this.activeId}/>
        </div>
    }
}

export default toNative<{}, {}>(ReceiptAccount)